# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.BigQuery.V2.Model.BigLakeConfiguration do
  @moduledoc """
  Configuration for BigLake managed tables.

  ## Attributes

  *   `connectionId` (*type:* `String.t`, *default:* `nil`) - Optional. The connection specifying the credentials to be used to read and write to external storage, such as Cloud Storage. The connection_id can have the form `{project}.{location}.{connection_id}` or `projects/{project}/locations/{location}/connections/{connection_id}".
  *   `fileFormat` (*type:* `String.t`, *default:* `nil`) - Optional. The file format the table data is stored in.
  *   `storageUri` (*type:* `String.t`, *default:* `nil`) - Optional. The fully qualified location prefix of the external folder where table data is stored. The '*' wildcard character is not allowed. The URI should be in the format `gs://bucket/path_to_table/`
  *   `tableFormat` (*type:* `String.t`, *default:* `nil`) - Optional. The table format the metadata only snapshots are stored in.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :connectionId => String.t() | nil,
          :fileFormat => String.t() | nil,
          :storageUri => String.t() | nil,
          :tableFormat => String.t() | nil
        }

  field(:connectionId)
  field(:fileFormat)
  field(:storageUri)
  field(:tableFormat)
end

defimpl Poison.Decoder, for: GoogleApi.BigQuery.V2.Model.BigLakeConfiguration do
  def decode(value, options) do
    GoogleApi.BigQuery.V2.Model.BigLakeConfiguration.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.BigQuery.V2.Model.BigLakeConfiguration do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
